/*全局*/
a{
    color: inherit;
    text-decoration: none;
}
body{
    position: relative;
}
li{
    list-style: none;
}
html{
    font-size: 14px;
}

/************************************************************/
/*                                                          */
/*                      框架部分代码                          */
/*                                                          */
/************************************************************/
header{
    background-size: cover;
    background-position: left center;
    position: relative;
    background-image: url("../image/bg_topbar_stu.jpg");
}
header h1{
    font-size: 150%;
    color: rgba(255,255,255,.5);
    font-weight: normal;
    padding-top: 1em;
    text-align: center;
}
header .self-info{
    padding: .5em;
    color: rgba(255,255,255,.9);
    text-align: right;
}
/*个人信息hover*/
header .self-info .hover-box{
    z-index:12;
    color: #959597;
    font-size: 1.1em;
    position: absolute;
    top: 100%;
    right: 0;
    width: 100%;
    pointer-events: none;
    background-color: rgba(255,255,255,.7);
    list-style: none;
    opacity: 0;
}
header .self-info .hover-box li{
    margin: .5em 1em;
}
header .self-info .hover-box img{
    width: 1em;
    height: 1em;
    object-fit: cover;
}
header .self-info .hover-box img,header.self-info .hover-box span{
    vertical-align: middle;
}
header .self-info:hover .hover-box{
    opacity: 1;
    pointer-events: initial;
}
/**************/


header .self-info .portrait{
    width: 1.5em;
    height: 1.5em;
    object-fit: cover;
}
header .self-info *{
    vertical-align: middle;
}
nav{
    display: flex;
}
.nav__item{
    flex-basis: 0;
    flex-grow: 1;
    background-color: rgb(239,239,239);
    color: #6b6c6d;
    text-align: center;
    font-size: 1.1em;
    padding: .75em 1em;
}
.nav__item.active{
    background-color: rgb(102,150,154);
    color: white;
}











.switcher{
    /*display: inline-flex;*/
}
.switcher__on,.switcher__off{
    margin: 0 .3em;
    /*flex-grow: 1;*/
    display: inline-block;
}
.switcher.on .switcher__on{
    color: #5ccbbb;
}
.switcher.off .switcher__off{
    color: #f96989;
}


/************************************************************/
/*                                                          */
/*                  主体从这里开始                             */
/*                                                          */
/*************************************************************/
.page-1{
    width: 100%;
    display: flex;
    flex-direction: column;
    height:100%;
}
.block.course-list,.block.course-info{
    flex-shrink: 0;
}
.block.chat-area{
    flex-grow: 1;
}
.block__title{
    background-color: rgb(239,239,239);
    color: #8d8d8d;
    padding: .75em 1em;
}
.course-list .block__title,.course-info .block__title{
    display: flex;
    position: relative;
}
.course-list .block__title>*,.course-info .block__title>*{
    flex-basis: 0;
    flex-grow: 1;
}
.chat-area .block__title{
    text-align: center;
}
.course-list .block__title:after,.course-info .block__title:after{
    content: "";
    position: absolute;
    top: .75em;
    right: .5em;
    width: 1em;
    height: 1em;
    background-image: url("../image/arrow_right.png");
    background-repeat: no-repeat;
    background-size: contain;
    transform: rotateZ(90deg);
}
.course-list .block__content{
    display: flex;
}
.course-list .block__content ul{
    overflow-y: scroll;
    flex-basis: 0;
    flex-grow: 1;
    padding: 1em;
}
.course-info .block__content{
    display: flex;
}
.course-info .course-introduce{
    flex-grow: 1;
    padding: 1em;
    color: #6e6e6e;
}
.course-introduce h1{
    text-align: center;
    padding: .3em;
}
.course-info .button-group{
    flex-shrink: 0;
    display: flex;
    justify-content: space-around;
    flex-direction: column;
    align-items: stretch;
    padding: 0 1em;
    color: white;
    min-height: 100px;
}
.course-info .button-group .button{
    background-color: rgb(92,203,187);
    border-radius: 5px;
    padding: .5em .75em;
    text-align: center;
}
.course-info .button-group .button.disabled{
    background-color: rgb(187,187,187);
}
.chat-area{
    display: flex;
    flex-direction: column;
}
.chat-area .block__title{
    flex-shrink: 0;
}
.chat-area .block__content{
    flex-grow: 1;
}
.chat-area .block__content{
    font-size: .9em;
    position: relative;
}
.message-block{
    padding: .5em .5em 0 .5em;
    box-sizing: border-box;
    position: absolute;
    width: 100%;
    left: 0;
    top: 0;
    bottom: 2.5em;
    /*background-color: red;*/
    overflow-y: scroll;
}
.person-message{
    display: flex;
    align-items: flex-start;
}
.person-message,.system-message{
    margin-bottom: 1em;
}
.person-message__info{
    flex-shrink: 0;
    margin: 0 .7em;
}
.person-message__info .portrait{
    width: 3em;
    height: 3em;
}
.person-message__info .name{
    display: block;
    text-align: center;
}
.person-message__content{
    flex-grow: 1;
    flex-basis: 0;
}
.person-message__content .wrapper{
    background-color: rgb(239,239,239);
    border-radius: 5px;
    padding: .75em;
    display: inline-block;
}
.system-message{
    text-align: center;
}
.system-message__content{
    display: inline-block;
    background-color: rgb(239,239,239);
    border-radius: 5px;
    padding: .3em 2em;
}
.pre-sending-area{
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
}
.pre-sending-area input{
    width: 100%;
    border-width: 0 0 1px 0;
    border-color: rgb(92,203,187);
    outline: none;
}
.pre-sending-area .button{
    background-color: rgb(92,203,187);
    display: inline-block;
    position: absolute;
    right: 1em;
    bottom: .3em;
    padding: .5em .75em;
    border-radius: 5px;
}

.pre-sending-area .button.disabled{
    background-color: gray;
}


.course-list .block__content,.course-info .block__content{
    height: 100px;
}
.block__content{
    transition-duration: .2s;
    transition-property: height;
}
.course-list.hidden .block__title:after,.course-info.hidden .block__title:after{
    transform: rotateZ(0);
}
.course-list.hidden .block__content,.course-info.hidden .block__content{
    overflow: hidden;
    height: 0;
}


#check-in.done{
    background-color: gray;
    color: white;
}

/************************************************************/
/*                                                          */
/*                      媒体查询(放在最后)                     */
/*                                                          */
/************************************************************/


html{
    height: 100%;
}
body{
    height: 100%;
    display: flex;
    flex-direction: column;
}
header,nav{
    flex-shrink: 0;
}
section.main{
    flex-grow: 1;
    flex-basis: 0;
    align-items: stretch;
    display: flex;
}